package com.tiancheng.trade.commom.web.model.response;

import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

import java.io.Serializable;
import java.math.BigDecimal;

/**
 * 清分规则
 */
@Getter
@Setter
@NoArgsConstructor
public class SettlementRuleResVO implements Serializable {
    /**
     * 规则类型(1:产品 2:通用)
     */
    public static final String RULE_TYPE_PRODUCT = "1";
    public static final String RULE_TYPE_PUBLIC = "2";
    /**
     * 结算类型(1:清分 2:自营，3：平台)
     */
    public static final String SETTLEMENT_TYPE_CLEAR = "1";
    public static final String SETTLEMENT_TYPE_SELF = "2";
    public static final String SETTLEMENT_TYPE_PLATFORM = "3";
    /**
     * 结算状态(0:未生效,1:已生效,2:已失效,3:作废)
     */
    public static final String SETTLEMENT_STATUS_NOT = "0";
    public static final String SETTLEMENT_STATUS_ING = "1";
    public static final String SETTLEMENT_STATUS_INVALID = "2";
    public static final String SETTLEMENT_STATUS_CANCEL = "3";
    /**
     * 清分周期类型(1:按天 2:按月)
     */
    public static final String CLEARING_CYCLE_MODE_DAY = "1";
    public static final String CLEARING_CYCLE_MODE_MONTH = "2";
    /**
     * 清分规则(1:百分比 2:平台固定金额 3:商户固定金额)
     */
    public static final String CLEARING_RULE_RATE = "1";
    public static final String CLEARING_RULE_NUM_P = "2";
    public static final String CLEARING_RULE_NUM_M = "3";
    private static final long serialVersionUID = -5785647572890196334L;

    /**
     * 清分规则类型
     * @see com.tiancheng.trade.commom.core.enums.SettleRuleTypeEnums
     */
    private String settleRuleType;
    /**
     * 清分规则编码
     */
    private String settleRuleCode;
    /**
     * 商户编号
     */
    private String merchantCode;

    /**
     * 产品编号——交易中台的product_id
     */
    private String productCode;

    /**
     * 结算类型(1:清分 2:自营，3：平台)
     */
    private String settlementType;

    /**
     * 清分周期类型(1:按天 2:按月)
     *
     */
    private String clearingCycleMode;

    /**
     * 清分周期值
     */
    private Integer clearingCycleValue;

    /**
     * 清分周期扩展值
     */
    private Integer clearingCycleValueExt;

    /**
     * 清分规则(1:百分比 2:平台固定金额 3:商户固定金额)
     */
    private String clearingRule;

    /**
     * 清分-平台应收-百分比
     */
    private BigDecimal platformPre;

    /**
     * 清分-平台应收-固定金额
     */
    private Integer platformFix;

    /**
     * 清分-商户应收-固定金额
     */
    private Integer merchantFix;

}
